# This file is part of BlackArch Linux ( https://www.blackarch.org/ ).
# See COPYING for license details.

pkgname=getsids
pkgver=0.0.1
pkgrel=4
pkgdesc='Getsids tries to enumerate Oracle Sids by sending the services command to the Oracle TNS listener. Like doing ‘lsnrctl service’.'
url='http://www.cqure.net/wp/getsids/'
groups=('blackarch' 'blackarch-database')
makedepends=('gcc')
depends=('glibc')
arch=('x86_64' 'aarch64')
license=('GPL')
source=("http://www.cqure.net/tools/$pkgname-src-$pkgver.tar.gz")
sha512sums=('df1a6d71849af4cfad79c86cd63661a3a2862d34c5ba8d195f89ec0da15ca74d6084348e36c473c078ebd23f48ca23490ccd2a3609f3ac4ad7576cf9acd2c86e')

build() {
  cd $pkgname

  ./configure --prefix=/usr

  make CC="gcc $CFLAGS"
}

package(){
  cd $pkgname

  install -dm 755 "$pkgdir/usr/bin"
  install -dm 755 "$pkgdir/usr/share/doc/$pkgname"

  install -Dm 755 "bin/$pkgname" "$pkgdir/usr/bin/$pkgname"
  install -Dm 644 -t "$pkgdir/usr/share/doc/$pkgname/" README
}

